3D Graphics Programming with QuickDraw 3D 1.5.4
Previous | QD3D Book | Overview | Chapter Contents | Next |
QuickDraw 3D provides routines that you can use to create and manipulate Macintosh draw contexts.
You can use the Q3MacDrawContext_New function to create a new Macintosh draw context.
TQ3DrawContextObject Q3MacDrawContext_New (
const TQ3MacDrawContextData *drawContextData);
The Q3MacDrawContext_New function returns, as its function result, a new draw context object having the characteristics specified by the drawContextData parameter. See "Macintosh Draw Context Structure" for information on the drawContextData parameter.
You can use the Q3MacDrawContext_GetWindow function to get the window associated with a Macintosh draw context.
TQ3Status Q3MacDrawContext_GetWindow (
TQ3DrawContextObject drawContext,
CWindowPtr *window);
You can use the Q3MacDrawContext_SetWindow function to set the window associated with a Macintosh draw context.
TQ3Status Q3MacDrawContext_SetWindow (
TQ3DrawContextObject drawContext,
const CWindowPtr window);
You can use the Q3MacDrawContext_Get2DLibrary function to get the two-dimensional drawing library associated with a Macintosh draw context.
TQ3Status Q3MacDrawContext_Get2DLibrary (
TQ3DrawContextObject drawContext,
TQ3MacDrawContext2DLibrary *library);
You can use the Q3MacDrawContext_Set2DLibrary function to set the two-dimensional drawing library associated with a Macintosh draw context.
TQ3Status Q3MacDrawContext_Set2DLibrary (
TQ3DrawContextObject drawContext,
TQ3MacDrawContext2DLibrary library);
You can use the Q3MacDrawContext_GetGXViewPort function to get the QuickDraw GX view port associated with a Macintosh draw context.
TQ3Status Q3MacDrawContext_GetGXViewPort (
TQ3DrawContextObject drawContext,
gxViewPort *viewPort);
The Q3MacDrawContext_GetGXViewPort function returns, in the viewPort parameter, the QuickDraw GX view port currently associated with the draw context specified by the drawContext parameter. If no view port is associated with the draw context or the two-dimensional graphics library is not set to kQ3Mac2DLibraryQuickDrawGX , Q3MacDrawContext_GetGXViewPort returns NULL in the viewPort parameter.
You can use the Q3MacDrawContext_SetGXViewPort function to set the QuickDraw GX view port associated with a Macintosh draw context.
TQ3Status Q3MacDrawContext_SetGXViewPort (
TQ3DrawContextObject drawContext,
const gxViewPort viewPort);
The Q3MacDrawContext_SetGXViewPort function sets the QuickDraw GX view port associated with the draw context specified by the drawContext parameter to the view port specified by the viewPort parameter. The two-dimensional graphics library associated with the specified draw context must be kQ3Mac2DLibraryQuickDrawGX .
You can use the Q3MacDrawContext_GetGrafPort function to get the QuickDraw graphics port associated with a Macintosh draw context.
TQ3Status Q3MacDrawContext_GetGrafPort (
TQ3DrawContextObject drawContext,
CGrafPtr *grafPort);
The Q3MacDrawContext_GetGrafPort function returns, in the grafPort parameter, the QuickDraw graphics port currently associated with the draw context specified by the drawContext parameter. If no graphics port is associated with the draw context or the two-dimensional graphics library is not kQ3Mac2DLibraryQuickDraw , Q3MacDrawContext_GetGrafPort returns NULL in the grafPort parameter.
You can use the Q3MacDrawContext_SetGrafPort function to set the QuickDraw graphics port associated with a Macintosh draw context.
TQ3Status Q3MacDrawContext_SetGrafPort (
TQ3DrawContextObject drawContext,
const CGrafPtr grafPort);
The Q3MacDrawContext_SetGrafPort function sets the QuickDraw graphics port associated with the draw context specified by the drawContext parameter to the graphics port specified by the grafPort parameter. The two-dimensional graphics library associated with the specified draw context must be kQ3Mac2DLibraryQuickDraw .
Previous | QD3D Book | Overview | Chapter Contents | Next |